:root {
    --primary-color: #6c5ce7;
    --secondary-color: #a29bfe;
    --accent-color: #fd79a8;
    --dark-color: #2d3436;
    --light-color: #f7f7f7;
    --gradient: linear-gradient(135deg, #6c5ce7, #a29bfe);
}

body {
    font-family: 'Poppins', sans-serif;
    background: var(--gradient);
    color: var(--dark-color);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    overflow-x: hidden;
}

body::before {
    content: '';
    position: absolute;
    width: 200%;
    height: 200%;
    background: url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23ffffff' fill-opacity='0.1' fill-rule='evenodd'%3E%3Cpath d='M0 40L40 0H20L0 20M40 40V20L20 40'/%3E%3C/g%3E%3C/svg%3E");
    top: -50%;
    left: -50%;
    z-index: 0;
}

.login-container {
    background-color: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 450px;
    position: relative;
    z-index: 1;
    animation: fadeInUp 0.8s ease-out;
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

.brand-logo {
    text-align: center;
    margin-bottom: 30px;
}

.brand-logo h1 {
    font-weight: 700;
    font-size: 2.2rem;
    color: var(--primary-color);
    margin-bottom: 5px;
}

.brand-logo p {
    color: #777;
    font-size: 1rem;
}

h2 {
    text-align: center;
    color: var(--dark-color);
    margin-bottom: 30px;
    font-weight: 600;
    position: relative;
}

h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 4px;
    background: var(--gradient);
    border-radius: 2px;
}

.form-group {
    margin-bottom: 25px;
}

label {
    display: block;
    margin-bottom: 8px;
    color: #555;
    font-weight: 500;
}

input[type="text"],
input[type="password"] {
    width: 100%;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 10px;
    font-size: 16px;
    box-sizing: border-box;
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
}

input[type="text"]:focus,
input[type="password"]:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.1);
}

.btn-login {
    background: var(--gradient);
    color: white;
    border: none;
    padding: 15px 20px;
    border-radius: 50px;
    cursor: pointer;
    font-size: 16px;
    width: 100%;
    transition: all 0.3s ease;
    font-weight: 500;
    font-family: 'Poppins', sans-serif;
    margin-top: 10px;
}

.btn-login:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(108, 92, 231, 0.3);
}

.messages {
    margin-bottom: 20px;
}

.alert {
    padding: 12px 15px;
    border-radius: 10px;
    margin-bottom: 15px;
    border: none;
    font-weight: 500;
}

.alert-success {
    background-color: rgba(212, 237, 218, 0.8);
    color: #155724;
}

.alert-error {
    background-color: rgba(248, 215, 218, 0.8);
    color: #721c24;
}

.register-link {
    text-align: center;
    margin-top: 25px;
    color: #777;
}

.register-link a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.register-link a:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

.form-icon {
    position: relative;
}

.form-icon i {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #aaa;
}

.form-icon input {
    padding-right: 45px;
}

.floating-shapes {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 0;
    overflow: hidden;
}

.shape {
    position: absolute;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
}

.shape:nth-child(1) {
    width: 80px;
    height: 80px;
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}

.shape:nth-child(2) {
    width: 120px;
    height: 120px;
    top: 70%;
    left: 80%;
    animation-delay: 2s;
}

.shape:nth-child(3) {
    width: 60px;
    height: 60px;
    top: 40%;
    left: 85%;
    animation-delay: 4s;
}

@keyframes float {
    0% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(10deg); }
    100% { transform: translateY(0) rotate(0deg); }
}

@media (max-width: 576px) {
    .login-container {
        padding: 30px 20px;
    }
}